package com.wxtwxt.ruralmall.cart.service;

import com.wxtwxt.ruralmall.cart.vo.Cart;
import com.wxtwxt.ruralmall.cart.vo.CartItem;

import java.util.List;
import java.util.concurrent.ExecutionException;

/**
 * @author Wxt
 * @create 2023-04-24 21:50
 */
public interface CartService {
    CartItem addToCart(Long skuId, Integer num) throws ExecutionException, InterruptedException;

    CartItem getCartItem(Long skuId);

    Cart getCart() throws ExecutionException, InterruptedException;

    void checkItem(Long skuId, Boolean check);

    void countItem(Long skuId, Integer num);

    void deleteItem(Long skuId);

    List<CartItem> getCartItemList();
}
